#pragma once
#include <iostream>
#include <vector>
#include <string>

template<class T>
inline void printContainer(const T &container)
{
    for(const auto &elem : container)
    {
        std::cout << elem << std::endl;
    }
}

template<class T>
inline void printContainerOptional(const T &container)
{
    for(const auto &elem : container)
    {
        if(elem){
            std::cout << elem.value() <<std::endl;
        }
        else{
            std::cout << "元素无效" << std::endl;
        }
    }
}

template<class T>
inline void printContainerPair(const T &container)
{
    for(auto &elem : container)
    {
        std::cout << elem.first << " : " << elem.second << std::endl;
    }
}